package main

import (
	"fmt"
	_ "strings"
)

func AddUpper() func(int) int {
	var n = 10
	return func(x int) int {
		n += x // n = 11, 12 , 13
		return n
	}
}

func main() {
	f := AddUpper()
	fmt.Println(f(1)) // 11
	fmt.Println(f(1)) // 12
	fmt.Println(f(1)) // 13
}
